package cn.kepu.elearning.scheduler;

import cn.kepu.elearning.service.SyncService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;

/**
 * @author Endy
 * @date 2020-04-21 上午8:40
 **/
@Component
public class SyncScheduler {

    @Autowired
    private SyncService syncService;

    @Scheduled(cron = "${sync.cron}")
    public void sync() {
        syncService.sync();
    }
}
